﻿using Fast.ConfigureOptions;
using Microsoft.Extensions.Configuration;

namespace Fast.Extensions.DatabaseAccessor.EntityFrameworkCore
{
    /// <summary>
    /// 数据库连接选项
    /// </summary>
    [SkipScan]
    public class DatabaseConnectionOptions : IConfigureOptions<DatabaseConnectionOptions>
    {
        public ConnectionStrings ConnectionStrings { get; set; }

        public DatabaseConnectionOptions()
        {

        }

        public void PostConfigure(DatabaseConnectionOptions options, IConfiguration configuration)
        {
            ConnectionStrings ??= new ConnectionStrings();
        }
    }
}
